SUBROUTINE fcn_mayor(n, p, fval)
  USE commonvars
  IMPLICIT NONE

  INTEGER, INTENT(IN)     :: n
  REAL(8), INTENT(IN)     :: p(n)
  REAL(8), INTENT(OUT)    :: fval

  EXTERNAL mayorsolution
  
  CALL mayorsolution(n, p, fval)

END SUBROUTINE fcn_mayor
